/*
 * main.cpp
 *
 *  Created on: Oct 3, 2014
 *      Author: tanpro
 */
#include<iostream>
#include <stdio.h>
#include <fstream>
using namespace std;
void nhap(ifstream &infile)
{
	char filename[100];
	cout << "nhap vao duong dan file";
	cin>>filename;
	infile.open(filename);
}
int main(void)
{
	ifstream inputfile;//tap tin vao
	ofstream outputfile;// tap tin ra
	char chs;

	nhap(inputfile);
	outputfile.open("/home/tanpro/Desktop/c.txt");
	while (!inputfile.eof())
	{
		inputfile.get(chs);
		if(!inputfile.eof())
		{
			cout<<chs;

			outputfile<<chs;
		}
	}
	cout<<"/n ghi tap tin dc hoan thanh"<<endl;
	inputfile.close();
	outputfile.close();
}


